home *** CD-ROM | disk | FTP | other *** search
/ NeXT Education Software Sampler 1992 Fall / NeXT Education Software Sampler 1992 Fall.iso / Programming / Classes / 2.0_nxyPalette1.2 / nxyTestApp / Plot.h < prev    next >
Encoding:
Text File  |  1992-05-18  |  3.0 KB  |  112 lines

  1.  
  2. /* Generated by Interface Builder */
  3.  
  4. #import <objc/Object.h>
  5. #import <appkit/nextstd.h>
  6. #import <appkit/Form.h>
  7. #import <appkit/Button.h>
  8. #import <stdio.h>
  9.  
  10. @interface Plot:Object
  11. {
  12. //    id    mainTitle;        /* the main title object */
  13. //    id    yMax;            /* the yMax object */
  14. //    id    xMax;            /* the xMax object */
  15.     id    canvas;            /* the PlotView object */
  16. //    id    yMin;            /* the yMin object */
  17. //    id    xMin;            /* the xMin object */
  18. //    id    yInc;            /* the yInc object */
  19. //    id    xInc;            /* the xInc object */
  20. //    id    yTitle;            /* the yTitle object */
  21. //    id    xTitle;            /* the xTitle object */
  22. //    id  lineText;        /* the lineText object */
  23. //    id  lineThickness;        /* the lineThickness object */
  24. //    id  gridOnOff;        /* the grid on/off button */
  25. //    id  borderBoxOnOff;        /* the border box on/off button */
  26. //    id  xLinLog;        /* the x-axis linear/logarithmic button */
  27.  //   id  yLinLog;        /* the y-axis linear/logarithmic button */
  28.  
  29. //    const char * maintitle;
  30. //    const char * xtitle;
  31. //    const char * ytitle;
  32.  
  33.     NXCoord *x;            /* the x coordinates */
  34.     NXCoord **y;        /* the y coordinates */
  35.     int npoints;        /* number of points  */
  36.     int ncurves;        /* number of curves  */
  37.  
  38.     NXPoint min;        /* min.x and min.y from xMin and yMin objects */
  39.     NXPoint max;        /* max.x and max.y from xMax and yMax objects */
  40.     NXPoint datamin;        /* xmin and ymin from the data */
  41.     NXPoint datamax;        /* xmax and ymax from the data */
  42.     
  43. }    
  44.  
  45. - (NXCoord *)xdata;
  46. - (NXCoord **)ydata;
  47.  
  48. - (int) nPoints;
  49. - (int) nCurves;
  50.  
  51. //- (const char *) provideXtitle;
  52. //- (const char *) provideYtitle;
  53. //- (const char *) provideMaintitle;
  54.  
  55. - (BOOL) shouldDrawGrid;
  56. - (BOOL) shouldDrawBox;
  57. - (BOOL) xaxisLog;
  58. - (BOOL) yaxisLog;
  59. - forceXaxisLinear;
  60. - forceYaxisLinear;
  61.  
  62. - (int)providelinestyle: (int)aCurve;
  63.                 /* 0=solid, 1=dash, 2=dot, 3=chain dash */
  64.                 /* 4=chain dot, 5=none */
  65. - (int)providesymbolstyle: (int)aCurve;
  66.                 /* 0=none, 1=circle, 2=x, 3=up triangle */
  67.                 /* 4=down triangle, 5=diamond, 6=square  */
  68.                 /* 7=plus */
  69.  
  70. - (int)providelinethickness;    /* 0=thin, 1=medium, 2=thick */
  71.  
  72. - (int)providesymbolsize;       /* 0=pixel, 1=small, 2=medium, 3=large */
  73.  
  74. - (float) provideXmin;
  75. - (float) provideXmax;
  76. - (float) provideXinc;
  77. - (float) provideYmin;
  78. - (float) provideYmax;
  79. - (float) provideYinc;
  80.  
  81. - resetXmin:(float)x;
  82. - resetXmax:(float)x;
  83. - resetXinc:(float)x;
  84. - resetYmin:(float)x;
  85. - resetYmax:(float)x;
  86. - resetYinc:(float)x;
  87.  
  88. - drawPlot:sender;
  89.  
  90. - (int) readDataFromFile:(FILE *)aDataStream;
  91. - (int) readDataFromStream:(NXStream *)aDataStream;
  92.  
  93. //Added by cwf to handle streams:
  94. -useDataStreamAndPlot:(NXStream *)dataStream;
  95.  
  96. - findMinAndMax;
  97.  
  98. - sanityCheck;  // Taken from 1.7
  99. - niceMinMaxInc;    // Taken from 1.7
  100.  
  101. - open:sender;
  102. - openFile:(char *)dataFile;
  103.  
  104. #define N_LINE_STYLES 6        /* number of line styles (including none) */
  105. #define N_SYMBOL_STYLES 8    /* number of symbol styles (including none) */
  106.  
  107. //Added to archive the instance variables
  108. - read:(NXTypedStream *)stream;
  109. - write:(NXTypedStream *)stream;
  110.  
  111. @end
  112.